# !/usr/bin/python3
# -*- coding: utf-8 -*-

"""
参数配置表模型类
----------------------------------------------------
@Project :   xinhou-openai-framework
@File    :   TestSchema.py
@Contact :   sp_hrz@qq.com

@Modify Time      @Author    @Version    @Desciption
------------      -------    --------    -----------
2023/04/16 22:04  peng.shen   v1.0.0     None
"""
from typing import Optional, Union

from pydantic import BaseModel, Field
from pydantic.v1 import Required


class ResSummaryCallbackSchema(BaseModel):
    """
    训练文件数据同步返回数据模型
    """
    result: Optional[str] = Field(title="业务端执行结果")


class TestResSummaryCallbackSchema(BaseModel):
    """
    通用返回模型
    """

    code: Optional[int] = Field(default=Required, title="编码", description="返回请求编码")
    msg: Optional[str] = Field(default=Required, title="消息", description="返回请求消息")
    data: Optional[ResSummaryCallbackSchema] = Field(default=None, title="内容",
                                                     description="返回内容")
